# Contributor: fossdd <fossdd@pwned.life>
# Maintainer: fossdd <fossdd@pwned.life>
pkgname=py3-requests-oauthlib
pkgver=2.0.0
pkgrel=0
pkgdesc="First-class OAuth library support for Requests"
options="!check" # No tox.ini file
url="https://pypi.org/project/requests-oauthlib"
arch="noarch"
license="ISC"
depends="
	py3-oauthlib
	py3-requests
	python3
	"
makedepends="
	py3-gpep517
	py3-setuptools
	py3-wheel
	"
checkdepends="
	py3-mock
	py3-requests-mock
	py3-tox
	"
subpackages="$pkgname-pyc"
source="https://files.pythonhosted.org/packages/source/r/requests-oauthlib/requests-oauthlib-$pkgver.tar.gz"
builddir="$srcdir/requests-oauthlib-$pkgver"

replaces="py-requests-oauthlib" # Backwards compatibility
provides="py-requests-oauthlib=$pkgver-r$pkgrel" # Backwards compatibility

build() {
	gpep517 build-wheel \
		--wheel-dir .dist \
		--output-fd 3 3>&1 >&2
}

check() {
	tox --sitepackages
}

package() {
	python3 -m installer -d "$pkgdir" \
		.dist/*.whl
}

sha512sums="
f15851aa27a19053c1bd6ccc7e1fcbc24b5c9e3e4ced736754e34ff8121a3d9be9f4f9ff878cbd2a75ca5803e25522807b4ace19cb0f64a88844158fdf7d098f  requests-oauthlib-2.0.0.tar.gz
"
